home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Mac-Source 1994 July
/
Mac-Source_July_1994.iso
/
Other Langs
/
mpw yacc ƒ src
/
defs.h
< prev
next >
Wrap
Text File
|
1989-11-19
|
1KB
|
52 lines
#ifndef DEFS
#define DEFS
/* character names */
#define NUL '\0' /* the null character */
#ifdef MPWC
#define NEWLINE '\015' /* line feed */
#define CR '\012' /* carriage return */
#else
#define NEWLINE '\n' /* line feed */
#define CR '\r' /* carriage return */
#endif
#define SP ' ' /* space */
#define BS '\b' /* backspace */
#define HT '\t' /* horizontal tab */
#define VT '\013' /* vertical tab */
#define FF '\f' /* form feed */
#define DEL '\177' /* delete */
#define QUOTE '\'' /* single quote */
#define DOUBLE_QUOTE '\"' /* double quote */
#define BACKSLASH '\\' /* backslash */
/* some character macros */
#define IS_NUMERIC(c) ((c) >= '0' && (c) <= '9')
#define IS_OCTAL(c) ((c) >= '0' && (c) <= '7')
#define NUMERIC_VALUE(c) ((c) - '0')
#define PRINTABLE(c) ((c) >= SP && (c) < DEL)
/* miscellaneous definitions */
#define LOCAL static
#define NIL(t) ((t *) 0)
#ifdef AZTECC
#define getc agetc
#define putc aputc
#endif
#ifdef MPWC
#define MACINTOSH
#endif
#ifdef AZTECC
#define MACINTOSH
#endif
#endif